package com.shajj.movie.subtitle;

import java.io.IOException;
import java.util.List;
import java.util.logging.Logger;

import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.shajj.movie.Subtitle;


@SuppressWarnings("serial")
public class SubtitleServlet extends HttpServlet {
	private static final Logger log = Logger.getLogger("shajj");

	public void doGet(HttpServletRequest req, HttpServletResponse resp) throws IOException {
		resp.setContentType("text/plain;charset=utf-8");
		List<Subtitle> list = SubtitleDataManager.getInstance().getByPage(0, 20);
		resp.getWriter().write(list.toString());
		log.info(list.toString());
	}


}
